#include <iostream>
#include <cstring>
int main() {
    const char *a1 = "Apple";
    const char *a2 = "Google";
    const char *a3 = "Microsoft";
    int len = strlen(a3);
    for(int i=0;i<=len;i++)
    {
        std::cout.write(a3,i)<<"\n";
    }
    for(int i=len;i>0;i--)
    {
        std::cout.write(a3,i)<<"\n";
    }
    std::cout.write(a1,len)<<"\n";//超过a1后继续打印输出流中的信息，空格页数出
    return 0;
}